//
//  DrawView.h
//  GLGW_Shoping
//
//  Created by yang on 2018/11/29.
//  Copyright © 2018年 yang. All rights reserved.
//

#import <UIKit/UIKit.h>

typedef NS_ENUM(NSInteger,ChartViewType){
    LineChartViewType,  //折线图
    BarChartViewType,   //柱状图
    PieChartViewType    //饼状图
};

NS_ASSUME_NONNULL_BEGIN

@interface DrawView : UIScrollView
//图形类型
@property (assign, nonatomic) ChartViewType chartViewType;

//是否动态绘制
@property (assign, nonatomic) BOOL isAnimation;

/**
 *  @author li_yong
 *
 *  构造方法
 *
 *  @param frame      frame
 *  @param dataSource 数据源
 *  @param type       绘图类型
 *  @isAnimation      是否动态绘制
 *
 */
- (id)initWithFrame:(CGRect)frame
     withDataSource:(NSMutableArray *)dataSource
           withType:(ChartViewType)type
      withAnimation:(BOOL)isAnimation;

@property(nonatomic,copy) void(^Block_DrawBot)(GLGWButton * drawBut);
@end

NS_ASSUME_NONNULL_END
